package org.seckill.dao;

import org.apache.ibatis.annotations.Param;
import org.seckill.entity.Seckill;
import org.springframework.stereotype.Repository;

import java.util.Date;
import java.util.List;

/**
 * Created by sanmao on 2017/6/15.
 */
public interface SecKillDao {

    //减库存
    int reduceNumber(@Param("seckillId") long seckillId,@Param("killTime") Date killTime);

    Seckill queryById(long secKillId);

    //根据偏移量查询秒杀商品列表
    List<Seckill> queryAll(@Param("offset")int offset,@Param("limit") int limit);

}
